$().ready(function() {
	ajax("");
});

function ajax(type){
	$.ajax({
		cache : true,
		type : "GET",
		url : "/shop/Statistical/comprehensive",
		async : false,
		data:{type:type},
		error : function(request) {
			parent.layer.alert("Connection error");
		},
		success : function(data) {
			$("#paymoney").val(data.paymoney);
			$("#countsuccess").val(data.countsuccess);
			$("#validpaymoney").val(data.validpaymoney);
			$("#invalidcount").val(data.invalidcount);
			$("#invalidpaymoney").val(data.invalidpaymoney);
			$("#endordercount").val(data.endordercount);
			$("#endordermoneycount").val(data.endordermoneycount);
			
			
			$("#isvipcount").val(data.isvipcount);
			$("#orderisvip").val(data.orderisvip);
			$("#isviporder").val(data.isviporder);
			$("#vippaymoneycount").val(data.vippaymoneycount);
			$("#vippurchaserate").val(data.vippurchaserate);
			$("#noisviporder").val(data.noisviporder);
			$("#novippaymoneycount").val(data.novippaymoneycount);
			
			$("#youbicount").val(data.youbicount);
			
		}
	});
}

function order() {
	layer.open({
		type : 2,
		title : '订单',
		maxmin : true,
		shadeClose : false, // 点击遮罩关闭层
		area : [ '1000px', '600px' ],
		content : '/shop/Statistical/order' // iframe的url
	});
}

function orderproduct() {
	layer.open({
		type : 2,
		title : '订单商品',
		maxmin : true,
		shadeClose : false, // 点击遮罩关闭层
		area : [ '1000px', '600px' ],
		content : '/shop/Statistical/orderproduct'// iframe的url
	});
}
